import Home from "../pages/Home"
import Login from "../pages/Login"

// 二级路由
import Management from '../pages/home/Management'
import User from '../pages/home/User'
import Exam from '../pages/home/Exam'
import Class from '../pages/home/Class'
import Read from '../pages/home/Read'

export default [
    {
        path: "/login",
        component: Login
    },
    {
        path: "/home",
        component: Home,
        auth: ["管理员", "出题者", "浏览者"],
        children: [
            {
                path: "/home/Management",
                component: Management,
                title: "试题管理",
                auth: ["管理员", "出题者", "浏览者"]
            },
            {
                path: "/home/User",
                component: User,
                title: "用户管理",
                auth: ["管理员", "出题者"],
            },
            {
                path: "/home/Exam",
                component: Exam,
                title: "考试管理",
                auth: ["管理员"],
            },
            {
                path: "/home/Class",
                component: Class,
                title: "班级管理",
                auth: ["管理员", "出题者"],
            },
            {
                path: "/home/Read",
                component: Read,
                title: "阅卷管理",
                auth: ["管理员"]
            }
        ]
    }
]